#include <cstdio>
#include <cstring>
#include <cctype>
char *rev="A   3  HIL JM O   2TUVWXY51SE Z  8 ";
char *msg[]={" -- is not a palindrome."," -- is a regular palindrome.",
" -- is a mirrored string."," -- is a mirrored palindrome."};
char r(char c)
{
    if(isalpha(c)) return rev[c-'A'];
    return rev[c-'0'+25];
}
int main()
{
    char s[21];
    int p,m;
    while(scanf("%s",s)==1)
    {
        p=m=1;
        int l=strlen(s);
        for(int i=0;i<(l+1)/2;i++)
        {
            if(s[i]!=s[l-i-1]) p=0;
            if(r(s[i])!=(s[l-i-1])) m=0;
        }
        printf("%s%s\n\n",s,msg[p+2*m]);
    }
    return 0;
}

